package com.yanqu.road.entity.log.cross.hsisland;

import com.yanqu.road.entity.FieldTypeAnnotation;
import com.yanqu.road.entity.log.ServerBaseLog;
import com.yanqu.road.entity.log.maidian.BaseLogEntity;

@FieldTypeAnnotation(tableName = "t_l_ck_hs_island_score", desc = "海神岛-积分日志", autoSave = true, dataUpload = true, eventName = "seagod_score", uploadCk = true, isCross = true)
public class LogCrossHsIslandScore extends ServerBaseLog {

    @FieldTypeAnnotation(desc = "活动ID", dataAttribute = "activityid", isIndex = true)
    private int activityId;

    @FieldTypeAnnotation(desc = "分组ID", dataAttribute = "group_id", isIndex = true)
    private int groupId;

    @FieldTypeAnnotation(desc = "商会ID", dataAttribute = "guild_id")
    private String unionId;

    @FieldTypeAnnotation(desc = "用户id", isIndex = true)
    private long userId;

    @FieldTypeAnnotation(desc = "变更值", dataAttribute = "seagod_scorenum")
    private long changeScore;

    @FieldTypeAnnotation(desc = "玩家总积分", dataAttribute = "seagod_scorenow")
    private String score;

    @FieldTypeAnnotation(desc = "商会总积分", dataAttribute = "seagod_scoreguild")
    private String unionScore;

    public LogCrossHsIslandScore(int activityId, int groupId, String unionId, long userId, long changeScore, long score, long unionScore) {
        this.activityId = activityId;
        this.groupId = groupId;
        this.unionId = unionId;
        this.userId = userId;
        this.changeScore = changeScore;
        this.score = String.valueOf(score);
        this.unionScore = String.valueOf(unionScore);
    }


    @Override
    public long getUserId() {
        return userId;
    }
}
